package edu.fdzc.learn.entity.vo;



import lombok.Data;
import javax.validation.constraints.NotNull;
import java.util.List;

/**
 * 考试创建VO
 */
@Data
public class ExamCreateVO {
    /**
     * 课程ID
     */
    @NotNull(message = "课程ID不能为空")
    private Long courseId;

    /**
     * 考试标题
     */
    @NotNull(message = "考试标题不能为空")
    private String title;

    /**
     * 考试题目列表
     */
    private List<QuestionCreateDTO> questions;

    /**
     * 题目创建DTO
     */
    @Data
    public static class QuestionCreateDTO {
        @NotNull(message = "题目类型不能为空")
        private String type;

        @NotNull(message = "题目内容不能为空")
        private String question;

        @NotNull(message = "题目选项不能为空")
        private String options;
        @NotNull(message = "正确答案不能为空")
        private String correctAnswer;
    }
}